A query optimizer can analyze multiple query plans that can be performed to execute a received user query. The query optimizer can determine and select a best performing query plan. A query plan can be represented as a tree that includes a set of nodes. Each node of the tree can represent an operation to perform when the query is executed. Query plans can vary in estimated performance, such as due to differences in join ordering and other differences.